// default package
// Generated 28 Jul, 2014 8:04:07 PM by Hibernate Tools 3.4.0.CR1
package com.galaxy.bean;

import java.util.Date;
import java.util.HashSet;
import java.util.Set;
import javax.persistence.Column;
import javax.persistence.Entity;
import javax.persistence.FetchType;
import javax.persistence.GeneratedValue;
import static javax.persistence.GenerationType.IDENTITY;
import javax.persistence.Id;
import javax.persistence.JoinColumn;
import javax.persistence.JoinTable;
import javax.persistence.ManyToMany;
import javax.persistence.Table;
import javax.persistence.Temporal;
import javax.persistence.TemporalType;

/**
 * CmsPage generated by hbm2java
 */
@Entity
@Table(name = "cms_page", catalog = "magento")
public class CmsPage implements java.io.Serializable {

	private Short pageId;
	private String title;
	private String rootTemplate;
	private String metaKeywords;
	private String metaDescription;
	private String identifier;
	private String contentHeading;
	private String content;
	private Date creationTime;
	private Date updateTime;
	private short isActive;
	private short sortOrder;
	private String layoutUpdateXml;
	private String customTheme;
	private String customRootTemplate;
	private String customLayoutUpdateXml;
	private Date customThemeFrom;
	private Date customThemeTo;
	private Set coreStores = new HashSet(0);

	public CmsPage() {
	}

	public CmsPage(String identifier, short isActive, short sortOrder) {
		this.identifier = identifier;
		this.isActive = isActive;
		this.sortOrder = sortOrder;
	}

	public CmsPage(String title, String rootTemplate, String metaKeywords,
			String metaDescription, String identifier, String contentHeading,
			String content, Date creationTime, Date updateTime, short isActive,
			short sortOrder, String layoutUpdateXml, String customTheme,
			String customRootTemplate, String customLayoutUpdateXml,
			Date customThemeFrom, Date customThemeTo, Set coreStores) {
		this.title = title;
		this.rootTemplate = rootTemplate;
		this.metaKeywords = metaKeywords;
		this.metaDescription = metaDescription;
		this.identifier = identifier;
		this.contentHeading = contentHeading;
		this.content = content;
		this.creationTime = creationTime;
		this.updateTime = updateTime;
		this.isActive = isActive;
		this.sortOrder = sortOrder;
		this.layoutUpdateXml = layoutUpdateXml;
		this.customTheme = customTheme;
		this.customRootTemplate = customRootTemplate;
		this.customLayoutUpdateXml = customLayoutUpdateXml;
		this.customThemeFrom = customThemeFrom;
		this.customThemeTo = customThemeTo;
		this.coreStores = coreStores;
	}

	@Id
	@GeneratedValue(strategy = IDENTITY)
	@Column(name = "page_id", unique = true, nullable = false)
	public Short getPageId() {
		return this.pageId;
	}

	public void setPageId(Short pageId) {
		this.pageId = pageId;
	}

	@Column(name = "title")
	public String getTitle() {
		return this.title;
	}

	public void setTitle(String title) {
		this.title = title;
	}

	@Column(name = "root_template")
	public String getRootTemplate() {
		return this.rootTemplate;
	}

	public void setRootTemplate(String rootTemplate) {
		this.rootTemplate = rootTemplate;
	}

	@Column(name = "meta_keywords", length = 65535)
	public String getMetaKeywords() {
		return this.metaKeywords;
	}

	public void setMetaKeywords(String metaKeywords) {
		this.metaKeywords = metaKeywords;
	}

	@Column(name = "meta_description", length = 65535)
	public String getMetaDescription() {
		return this.metaDescription;
	}

	public void setMetaDescription(String metaDescription) {
		this.metaDescription = metaDescription;
	}

	@Column(name = "identifier", nullable = false, length = 100)
	public String getIdentifier() {
		return this.identifier;
	}

	public void setIdentifier(String identifier) {
		this.identifier = identifier;
	}

	@Column(name = "content_heading")
	public String getContentHeading() {
		return this.contentHeading;
	}

	public void setContentHeading(String contentHeading) {
		this.contentHeading = contentHeading;
	}

	@Column(name = "content", length = 16777215)
	public String getContent() {
		return this.content;
	}

	public void setContent(String content) {
		this.content = content;
	}

	@Temporal(TemporalType.TIMESTAMP)
	@Column(name = "creation_time", length = 19)
	public Date getCreationTime() {
		return this.creationTime;
	}

	public void setCreationTime(Date creationTime) {
		this.creationTime = creationTime;
	}

	@Temporal(TemporalType.TIMESTAMP)
	@Column(name = "update_time", length = 19)
	public Date getUpdateTime() {
		return this.updateTime;
	}

	public void setUpdateTime(Date updateTime) {
		this.updateTime = updateTime;
	}

	@Column(name = "is_active", nullable = false)
	public short getIsActive() {
		return this.isActive;
	}

	public void setIsActive(short isActive) {
		this.isActive = isActive;
	}

	@Column(name = "sort_order", nullable = false)
	public short getSortOrder() {
		return this.sortOrder;
	}

	public void setSortOrder(short sortOrder) {
		this.sortOrder = sortOrder;
	}

	@Column(name = "layout_update_xml", length = 65535)
	public String getLayoutUpdateXml() {
		return this.layoutUpdateXml;
	}

	public void setLayoutUpdateXml(String layoutUpdateXml) {
		this.layoutUpdateXml = layoutUpdateXml;
	}

	@Column(name = "custom_theme", length = 100)
	public String getCustomTheme() {
		return this.customTheme;
	}

	public void setCustomTheme(String customTheme) {
		this.customTheme = customTheme;
	}

	@Column(name = "custom_root_template")
	public String getCustomRootTemplate() {
		return this.customRootTemplate;
	}

	public void setCustomRootTemplate(String customRootTemplate) {
		this.customRootTemplate = customRootTemplate;
	}

	@Column(name = "custom_layout_update_xml", length = 65535)
	public String getCustomLayoutUpdateXml() {
		return this.customLayoutUpdateXml;
	}

	public void setCustomLayoutUpdateXml(String customLayoutUpdateXml) {
		this.customLayoutUpdateXml = customLayoutUpdateXml;
	}

	@Temporal(TemporalType.DATE)
	@Column(name = "custom_theme_from", length = 10)
	public Date getCustomThemeFrom() {
		return this.customThemeFrom;
	}

	public void setCustomThemeFrom(Date customThemeFrom) {
		this.customThemeFrom = customThemeFrom;
	}

	@Temporal(TemporalType.DATE)
	@Column(name = "custom_theme_to", length = 10)
	public Date getCustomThemeTo() {
		return this.customThemeTo;
	}

	public void setCustomThemeTo(Date customThemeTo) {
		this.customThemeTo = customThemeTo;
	}

	@ManyToMany(fetch = FetchType.LAZY)
	@JoinTable(name = "cms_page_store", catalog = "magento", joinColumns = { @JoinColumn(name = "page_id", nullable = false, updatable = false) }, inverseJoinColumns = { @JoinColumn(name = "store_id", nullable = false, updatable = false) })
	public Set getCoreStores() {
		return this.coreStores;
	}

	public void setCoreStores(Set coreStores) {
		this.coreStores = coreStores;
	}

}
